<?php echo form_fieldset('Pago Cliente Modificar');?>
<table border=0 align="center"> 
  
<?php
echo form_hidden(array('name'=>'base_url','id' => 'base_url','value' =>base_url()));
echo form_open('pago_clientes_controller/actualizar_pago_cliente/'.$id_encriptado,$attributes= array('name' => "formPagoClienteModificar"));
?> 

		<tr>
		<td colspan="2"><?php echo $this->session->flashdata('fecha_no_existe');?></td>
       </tr>
		     <tr>
				<td><?php echo form_label('Fecha de la Venta:', 'lbl_fecha_venta');?></td>	
				<td><?php echo form_input(array('name' =>'fecha_venta','size' => '10','class' => 'input','readOnly'=>'true','id'=>'fecha_venta','value' =>date('d/m/Y',strtotime($fecha_venta)),set_value('fecha_venta'))) ?>
				 <?php $img = img(array('src'=>'/imagenes/boton_date.png', 'valign'=>'middle' ));?>		
				<?php echo anchor('', $img,array('id'=>'calendario_venta')); ?>
				<td><?php echo form_error('fecha_venta', '<div class="error">', '</div>'); ?></td>
			</tr>
			<tr>
			    <td><?php echo form_label('nro_documento', 'lbl_documento');?></td>	
				<td><?php echo form_input(array('name' => 'nro_documento','value' =>$nro_documento,set_value('nro_documento')))?></td>
				<td><?php echo form_error('nro_documento', '<div class="error">', '</div>'); ?></td>
			
			</tr>
			
			<tr>
			   <td><?php echo form_label('Monto:', 'lbl_monto');?></td>	
		       <td><?php echo form_input(array('name' =>'monto','value' =>$monto,set_value('monto'))) ?></td>
		       <td><?php echo form_error('monto', '<div class="error">', '</div>'); ?></td>
			</tr>
			<tr>	
				<td><?php echo form_label('Fecha:', 'lbl_fecha');?></td>	
		       <td><?php echo form_input(array('name' =>'fecha','size' => '10','class' => 'input','readOnly'=>'true','id'=>'fecha','value' =>date('d/m/Y',strtotime($fecha)),set_value('fecha'))) ?>
		       <?php $img = img(array('src'=>'/imagenes/boton_date.png', 'valign'=>'middle' ));?>		
	          <?php echo anchor('', $img,array('id'=>'calendario')); ?>
	     	<td><?php echo form_error('fecha', '<div class="error">', '</div>'); ?></td>
			</tr>
			<tr>
		       <td><?php echo form_label('formapago', 'lbl_forma_pago');?></td>	
		        <td> <?php echo form_dropdown('formapago',$formapago,$this->validation->id_forma_pago); ?> </td>
				<td><?php echo form_error('formapago', '<div class="error">', '</div>'); ?></td>
			</tr>
			<tr>
			     <td><?php echo form_label('Tipo Banco', 'lbl_tipo_banco');?></td>
				 <td> <?php echo form_dropdown('bancos', $bancos,$this->validation->id_banco); ?> </td>
				 <td><?php echo form_error('bancos', '<div class="error">', '</div>'); ?></td>
			</tr>
			<tr>
			    <td colspan="2" align="right"><?php echo form_submit(array('name'=> 'btn_guardar','value'=>'Guardar','class'=>'Boton')) ?>
			    <?php echo form_reset(array('name'=> 'btn_cancelar','value'=>'Cancelar','class'=>'Boton'))?></td>
			</tr>
			<tr>
			   <td><?php echo anchor('pago_clientes_controller/index/','Regresar a la lista  de Clientes',array('class'=>'add'));?></td>
			</tr>
			
			<script type="text/javascript">
  			function dateChanged(calendar) {
    			if (calendar.dateClicked) {
      			var y = calendar.date.getFullYear();
      			var m = calendar.date.getMonth();
      			var d = calendar.date.getDate();
      			window.location = "#";
    			}
  			};  
  
  			Calendar.setup(
    			{
      				inputField  : "fecha",
      				ifFormat    : "%d/%m/%Y",
      				button      : "calendario"
    			}
  			);
  
		</script>

		<?php echo  form_close();?>
		
		</table>
		
	<?php echo form_fieldset_close(); ?>	
		